package com.dmap.analysispoint.utils;

import com.dmap.analysispoint.bo.DateAndNumBo;

import java.util.ArrayList;
import java.util.List;

public class ObjectTransitionArrayListUtils {

    /**
     *将List<DateAndNumBo>转化成List<List>
     */
    public static List<List> objectTransitionArrayList(List<DateAndNumBo> dateAndNumBoList) {
        List<List> list = new ArrayList<>();
        for (DateAndNumBo dateAndNumBo:dateAndNumBoList) {
            List<Long> longList = new ArrayList<>();
            longList.add(0,dateAndNumBo.getTimePoint());
            longList.add(1, Long.valueOf(dateAndNumBo.getNum()));
            list.add(longList);
        }
        return list;
    }
}
